package com.swak.boot.config.consistency.tcc;

import org.apache.dubbo.config.spring.context.properties.DubboConfigBinder;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import com.swak.Constants;

@Configuration
@ConditionalOnProperty(prefix = Constants.TCC_PREFIX, name = "deployMode", havingValue = "multi", matchIfMissing = false)
@ConditionalOnClass({ DubboConfigBinder.class })
public class DubboReferenceAutoConfiguration {

	@Bean
	public DubboReferencePostProcessor DubboReferencePostProcessor() {
		return new DubboReferencePostProcessor();
	}
}
